class Video < ActiveRecord::Base
  belongs_to :video_status, :foreign_key => 'status_id'
  has_many :events

  after_save :log_event

protected
  def log_event
    self.events.create({:status_id => status_id})
  end
end
